logo Learn HTML
  • Home
  • Tutorials
  • Practice
  • Quiz
  • Projects
  • About
  • Contact

HTML Course

  • HTML HOME
  • HTML Introduction
  • HTML Basic
  • HTML Element
  • HTML Attributes
  • HTML Headings
  • HTML Paragrapha
  • HTML Style
  • HTML Formattin
  • HTML Quotations
  • HTML Colors
  • HTML Css
  • HTML Links
  • HTML Image
  • HTML Favicon
  • Page Tittle
  • HTML Tables
  • HTML Lists
  • Block & Inline
  • HTML Div
  • HTML Classes
  • HTML Id
  • HTML Buttons
  • HTML Iframes
  • HTML File Paths
  • HTML Head
  • HTML Layout
  • HTML Symbols
  • HTML Emojis
  • HTML URL Encode
  • HTML VS XHTML
  • HTML FROM
  • HTML Form
  • Form Attributes
  • Form Elements
  • HTML Input Types
  • HTML Input Attributes
  • Input Form Attributes
  • HTML Graphics
  • HTML Canvas
  • HTML SVG
  • HTML Media
  • HTML Media
  • HTML Video
  • HTML Audio
  • HTML Plug-ins
  • HTML Youtube
  • HTML APIS
  • HTML Web APIS
  • HTML Geolocation
  • HTML Drag & Drop
  • Web Storage
  • Web Workers
  • HTML SSE
  • HTML Examples
  • HTML Examples
  • HTML Editor
  • HTML Quiz
  • HTML Exercises
  • HTML References
  • HTML Tag List
  • HTML Attributes
  • HTML Global Attributes
  • HTML Brower Support
  • HTML Events
  • HTML Colors
  • HTML Canvas
  • HTML Audio & Video
  • HTML Doctypes
  • HTML Character Sets
  • HTML URL Encode
  • Language Codes
  • HTTP Messages
  • HTTP Methods
  • PX to EM Converter
  • keyboard Shortcuts

HTML Uniform Resource Locators (URL)

A URL (Uniform Resource Locator) is the address used to access resources on the internet.

It is commonly known as a web address.

A URL can be:

  • A domain name (example: example.com)

  • An IP address (example: 192.168.1.1)

Most users prefer domain names because they are easier to remember.


What Is a URL?

A URL is used by web browsers to request pages or files from a web server.

When you type a web address into your browser, it sends a request to the server using that URL


Structure of a URL

A typical URL follows this structure:

scheme://prefix.domain:port/path/filename


Explanation of Each Part

  • Scheme → Defines the protocol (such as http or https)

  • Prefix → Usually www

  • Domain → The website name (example: example.com)

  • Port → Communication port (default is 80 for HTTP and 443 for HTTPS)

  • Path → The folder location on the server

  • Filename → The specific file or page being requested


Common URL Schemes

Scheme Meaning Purpose
http HyperText Transfer Protocol Standard web pages (not secure)
https Secure HyperText Transfer
Protocol
Encrypted and secure web pages
ftp File Transfer Protocol Uploading and downloading files
file Local File Accessing files on your computer

Today, HTTPS is strongly recommended because it provides encryption and security.


URL Encoding

URLs can only use the ASCII character set.

If a URL contains special characters or spaces, it must be encoded.


What Is URL Encoding?

URL encoding converts special or non-ASCII characters into a format that can be safely transmitted over the internet.

Special characters are replaced with:

% + hexadecimal value


Example

A space cannot appear directly in a URL.

It is replaced with:

  • +
  • or
  • %20

Character Encoding in HTML5

The default character set in HTML5 is UTF-8.

You should include this in your document:

<meta charset="UTF-8">


UTF-8 supports almost all characters and symbols worldwide.


Example of URL Encoding

If a URL contains special characters like:

Günter


It will be encoded before being sent to the server.

Different encoding standards may produce different encoded values, but UTF-8 is the modern standard.


Summary

  • A URL is the web address used to access resources online.

  • It follows a structured format (scheme, domain, path, etc.).

  • HTTPS is secure and recommended.

  • URLs must use ASCII characters.

  • Special characters must be URL encoded.

  • UTF-8 is the default character set in HTML5.

Try It Your Self

Sign Up For New
Update

HTML Basic
  1. HTML Basic
  2. HTML Element
  3. HTML Attributes
  4. HTML Headings
  5. HTML Paragrapha
  6. HTML Tables
  7. HTML Lists
HTML Advance
  1. HTML Div
  2. HTML Classes
  3. HTML Id
  4. HTML Buttons
  5. HTML Iframes
  6. HTML Symbols
  7. HTML Emojis